//--------------------------------------------------
// INFO la classe representant une variable
//--------------------------------------------------
package mjava.lib;

import java.io.Serializable;

public class INFO implements Serializable {

	private static final long serialVersionUID = -989868061940868175L;

	// le type
	private DTYPE type;
	
	// le deplacement
	private int depl;
	
	// nature
	private boolean varGloabl;

	// constructeur
	public INFO(DTYPE t, int d) {
		type = t;
		depl = d;
		varGloabl = false;
	}
	
	public INFO(DTYPE t, int d, boolean g) {
		type = t;
		depl = d;
		varGloabl = g;
	}
	
	public DTYPE getType() {
		return type;
	}

	public int getDeplacement() {
		return depl;
	}

	public int getTaille() {
		return type.getTaille();
	}
	// affichage
	public String toString() {
		return "; VAR : " + "type = " + type + ", depl = " + depl;
	}
	
	public boolean isGlobal() {
		return this.varGloabl;
	}
	
	public void setIsGlobal(boolean g) {
		this.varGloabl = g;
	}
}
